<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
    <script src="https://unpkg.com/lodash@4.17.21/lodash.js"></script>
</head>
<body>
<div id="Application">
    <button @click="click">button</button>
    <button @click="click2">button2</button>
</div>
<script>
    const App={
        data(){
            return{
                throttle:false
            }
        },
        methods:{
            click(){
                if (!this.throttle) {
                    console.log(Date())
                } else {
                    return;
                }
                this.throttle = true;
                setTimeout(() => {
                    this.throttle=false;
                },2000)
            },
            click2:_.debounce(function () {
                console.log("Date:",Date())
            },2000)
        }
    }
    Vue.createApp(App).mount("#Application")
</script>
</body>
</html>
